create table log(
	id number(10) primary key,
  	userName varchar2(100) not null,
	operation varchar2(100) not null,
	operationTime timestamp,
	remark varchar(200)
);
--alter table log add users varchar2(100) not null; 
create sequence log_id start with 0 minvalue 0 increment by 1;

SELECT CAST(sysdate AS TIMESTAMP) from dual;

alter session set nls_timestamp_format='yyyy-mm-dd hh24:mi:ss';

insert into log values(log_id.nextval,'admin login',to_timestamp(to_char(systimestamp,'YYYY-MM-DD HH24:MI:SS.FF'),'YYYY-MM-DD HH24:MI:SS.FF'),'');
insert into log values(log_id.nextval,'admin login',to_timestamp(to_char(sysdate,'YYYY-MM-DD HH24:MI:SS'),'YYYY-MM-DD HH24:MI:SS'),'');
insert into log values(log_id.nextval,'admin login',systimestamp,'');
commit;

select * from log;
truncate table log;

